package com.example.blog.service;

import com.example.blog.pojo.blog;
import org.apache.ibatis.javassist.NotFoundException;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public interface blogService {
    blog getBlog(Integer id);
    blog getBlogMarkdown(Integer id);
    List<blog> getBlog(String title);
    List<blog> getBlog(String title,boolean recommend);
    List<blog> getBlog(String title,String type,boolean recommend);
    List<blog> listBlog();
    List<blog> getBlogByType(String type);
    List<blog> getBlogByTag(Integer tag);
    void deleteBlog(Integer id);
    void saveBlog(blog blog);
    void updateBlog(Integer id ,blog blog) throws NotFoundException;
}
